//
//  JTCSM.h
//  JTCSM
//
//  Created by  程 强 on 15/9/11.
//  Copyright (c) 2015年 demon. All rights reserved.
//

#ifndef JTCSM_JTCSM_h
#define JTCSM_JTCSM_h

#import "UIButton+Custom.h"
#import "UILabel+Custom.h"
#import "UITextField+Custom.h"
#import "leftBarButtonItems+rightBarButtonItems.h"
#import "df.h"
#import "MyAlertView.h"
//#import "Masonry.h"
#import "LoadData.h"
//#import "NetworkRequest.h"
//#import "ImageNetWorkRequest.h"
#import <CommonCrypto/CommonDigest.h>
//#import "myNavigationBar.h"
#import "JTCSMSingle.h"
#import "APIKey.h"
#import <SDWebImage/UIImageView+WebCache.h>
#import <WHC_AutoLayoutKit/UITableViewCell+WHC_AutoHeightForCell.h>
#import <WHC_Model/NSObject+WHC_Model.h>
#import "MJRefresh.h"
#import "UIButton+addPro.h"
#import "UIView+LCLayout.h"
#import "YWUnlockView.h"
#import "YWFingerprintVerification.h"

#define IS_IPHONE_5 ( fabs( ( double )[ [ UIScreen mainScreen ] bounds ].size.height - ( double )568 ) < DBL_EPSILON

#define RGBACOLOR(r,g,b,a) [UIColor colorWithRed:(r)/255.0 green:(g)/255.0 blue:(b)/255.0 alpha:(a)]
#define KZhuTiRGB  RGBACOLOR(255,208,24, 1)
#define KUSERDEFAULTSET(value,key)  [[NSUserDefaults standardUserDefaults] setObject:value forKey:key]
#define KTokenString [KUSERDEFAULTGET(KInfoKey) objectForKey:@"token"] == nil ? @"":[KUSERDEFAULTGET(KInfoKey) objectForKey:@"token"]
#define Kmobile [KUSERDEFAULTGET(KInfoKey) objectForKey:@"mobile"] == nil ? @"":[KUSERDEFAULTGET(KInfoKey) objectForKey:@"mobile"]
#define Kis_code [KUSERDEFAULTGET(KInfoKey) objectForKey:@"is_code"] == nil ? @"":[KUSERDEFAULTGET(KInfoKey) objectForKey:@"is_code"]
#define Kis_verified [KUSERDEFAULTGET(KInfoKey) objectForKey:@"is_verified"] == nil ? @"":[KUSERDEFAULTGET(KInfoKey) objectForKey:@"is_verified"]
#define Ktel [KUSERDEFAULTGET(KInfoKey) objectForKey:@"tel"] == nil ? @"":[KUSERDEFAULTGET(KInfoKey) objectForKey:@"tel"]

#define KUSERDEFAULTGET(key)        [[NSUserDefaults standardUserDefaults] objectForKey:key]
#define KUSERDEFAULTRemoveAll(key)  [[NSUserDefaults standardUserDefaults] removeObjectForKey:key]
#define KResultOfKey(b)  [result objectForKey:b]
#define KDataOfKey(b)  [data objectForKey:b]
#define KInfoKey @"myinfo"
#define KSpace 14;
#define KCONTROLLERWith self.view.frame.size.width//控制器视图的宽
#define KCONTROLLERHeight self.view.frame.size.height//控制器视图的高
#define KVIEWwith self.frame.size.width//视图的宽
#define KVIEWheight self.frame.size.height//视图的高
#define KSCREENWidth (CGFloat)[UIScreen mainScreen].bounds.size.width //windon宽
#define KSCREENHeight [UIScreen mainScreen].bounds.size.height //windon高
#define KVIEW_X(a)          a.frame.size.width + a.frame.origin.x
#define KVIEW_Y(a)          a.frame.size.height + a.frame.origin.y

#define KVIEWOrigin_X(a)    a.frame.origin.x
#define KVIEWOrigin_Y(a)    a.frame.origin.y

#define CellHeight self.bounds.size.height
#define KagainChangeHeight 64
#define KAlertVTag 763484
#define _tab_bar_top_margin 236
#define _bonus_Height 90
#define _tab_bar_height 45
#define KbtnSize  25
#define KbtnY 87
#define KaddtextfieldWidth 10

#define KRefreshTime 0.3

#define KBtnWidth 80

#define KLTableViewWidth 0.2
#define KSTableViewWidth 0.8

#define KFloatMoney(a) @"%.2f¥",[a floatValue]

#define KZhangHuAnQuanKey @"zhiwenyanzheng"
#define KIsZhiWen @"isOn"
#define KIsShoushi @"isclose"


#define KReMenSearchKey @"ReMenSearchKey"

#define KDoubleLabelTitle @"KDoubleLabelTitle"
#define KDoubleLabelContent @"KDoubleLabelContent"

#define KCUSTOMNAVIGSTION_ALLOC [[leftBarButtonItems_rightBarButtonItems alloc]init];//自定义navigation
#define KLeftBarButtonItemFrame_text CGRectMake(10,12,20,20) //leftbar
#define KRightBarButtonItemFrame_text CGRectMake(0,2,40,40)
#define KLeftBarButtonItemFrame_image CGRectMake(0, 0, 0, 44)
#define KLeftimageFrame CGRectMake(35,12,20,20)
#define KRightBarButtonItemFrame_image CGRectMake(0,12,20.4,17)//rightbar


#define KURLHeadr(a) [NSString stringWithFormat:@"http://weixin.diangu888.com/app?m=Users&v=2.06&a=%@",a]
#define KURLPOSTHeadr(a) [NSString stringWithFormat:@"http://in.wz.51wangzhe.com.cn/%@/type/ios/v/1_16",a]
#define KBanBenInfo @"版本 1.0"
#define BaiduKey @"sgKinUxnMhGqIU9211nSb3Mnyed5g8wG"


#define KRadio @"first group"
#define KImageRadio @"KImageRadio"

#define KSaveLoginInfo      @"KSaveLoginInfo"
#define KSaveusername       @"KSaveusername"
#define KSavepassword       @"KSavepassword"
#define Kis_SaveLoginInfo   @"Kis_SaveLoginInfo"
#endif
